<?php
/**
 *  💡 免责声明：本软件不得用于商业用途，仅做学习交流
 *  ⚠️ 权利声明：本软件由版权人提供产品技术支持
 *  📅 项目编号：NX2025-0135
 */
use App\Api\Controllers\Commons\DataAnalysisApi;
use App\Api\Controllers\Commons\GroupApi;
use App\Api\Controllers\Commons\OtherApi;
use App\Api\Controllers\Commons\PaymentApi;
use App\Api\Controllers\Commons\PointApi;
use App\Api\Controllers\Commons\PoolApi;
use App\Api\Controllers\Commons\ProductApi;
use App\Api\Controllers\Commons\UploadApi;
use App\Api\Controllers\Commons\UserApi;
use Illuminate\Routing\Router;
use Illuminate\Support\Facades\Route;

Route::group([
    'namespace' => '',
    'middleware' => [],
], function (Router $router) {
    $router->post('upload_photo', [UploadApi::class, 'uploadPhoto'])->name('上传头像');
    $router->post('register', [UserApi::class, 'register'])->name('注册');
    $router->post('login', [UserApi::class, 'login'])->name('登录');
    $router->post('seed_sms', [UserApi::class, 'seedSms'])->name('发送短信');
    $router->post('clause', [UserApi::class, 'clause'])->name('条款');

    $router->post('retrieve_the_password', [UserApi::class, 'retrieveThePassword'])->name('找回密码');

    $router->post('hot_products', [ProductApi::class, 'hotProducts'])->name('热门商品');
    $router->post('new_products', [ProductApi::class, 'theLatestProducts'])->name('最新商品');
    $router->post('recommend_products', [ProductApi::class, 'recommendedProducts'])->name('推荐商品');
    $router->post('farmers_products', [ProductApi::class, 'farmersProducts'])->name('助农商品');
    $router->post('specialty_products', [ProductApi::class, 'specialtyProducts'])->name('特产商品');
    $router->post('search_product', [ProductApi::class, 'searchProduct'])->name('搜索商品');

    $router->post('product_category', [ProductApi::class, 'productCategory'])->name('产品类别');
    $router->post('products_list', [ProductApi::class, 'productsList'])->name('产品列表');
    $router->post('product_details', [ProductApi::class, 'productDetails'])->name('商品详情');
    $router->post('bean_package', [ProductApi::class, 'beanPackage'])->name('KC通证大礼包');
    $router->post('bean_package_details', [ProductApi::class, 'beanPackageDetails'])->name('KC通证大礼包详情');

    $router->post('carousels', [OtherApi::class, 'carousels'])->name('轮播图');
    $router->post('notice', [OtherApi::class, 'notice'])->name('公告');
    $router->post('notice_details', [OtherApi::class, 'noticeDetails'])->name('公告详情');

    $router->post('payment_account', [PaymentApi::class, 'paymentAccount'])->name('充值账户信息');

    $router->post('group_product', [GroupApi::class, 'groupProduct'])->name('拼团产品');
    $router->post('group_product_details', [GroupApi::class, 'groupProductDetails'])->name('拼团产品详情');
    $router->post('group_buying_sessions', [GroupApi::class, 'groupBuyingSessions'])->name('拼团场');

    $router->post('point_product', [PointApi::class, 'pointProduct'])->name('积分商品');
    $router->post('point_product_details', [PointApi::class, 'pointProductDetails'])->name('积分商品详情');

    $router->post('point_price', [PoolApi::class, 'pointPrice'])->name('价格走势');
    $router->post('poll_price', [PoolApi::class, 'pollPrice'])->name('积分池');

    $router->post('data_analysis', [DataAnalysisApi::class, 'dataAnalysis'])->name('数据分析');

    //BeanDestructionDetails
    $router->post('get_im_data', [UserApi::class, 'getImData']);
    $router->post('delete_channel', [UserApi::class, 'deleteChannel']);
    $router->post('get_im_user', [UserApi::class, 'getImUser']);

    $router->post('gen_qrcode', [UploadApi::class, 'genQrcode'])->name('生成二维码');
});
